<form class="layui-form info-form" action="">
	<input name="product_id" id="product_id" type="hidden" value="{$info.id}">
	<div class="layui-form-item">
		<div class="layui-input-block">
			<button type="button" class="layui-btn" id="btnAddPrice"><i class="layui-icon">&#xe67c;</i>添加阶梯报价</button>
		</div>
	</div>
	<volist name="info.priceList" id="val">
	<div class="layui-form-item">
		<div class="layui-inline">
			<label class="layui-form-label">最小个数：</label>
			<div class="layui-input-inline">
				<input name="min_num[]" value="{$val.min_num}" lay-verify="required" autocomplete="off" placeholder="请输入商品最小个数" class="layui-input" type="text">
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">最大个数：</label>
			<div class="layui-input-inline">
				<input name="max_num[]" value="{$val.max_num}" lay-verify="" placeholder="请输入商品最大个数" autocomplete="off" class="layui-input" type="text">
			</div>
		</div>
		<div class="layui-inline">
			<label class="layui-form-label">价格/元：</label>
			<div class="layui-input-inline">
				<input name="price[]" value="{$val.price}" lay-verify="required" placeholder="请输入商品价格(单位：元)" autocomplete="off" class="layui-input" type="text">
			</div>
		</div>
	</div>
	</volist>
	<div class="layui-form-item submitForm">
		<div class="layui-input-block">
			<button class="layui-btn" lay-submit="" lay-filter="submitForm" id="submitForm">立即提交</button>
			<button type="reset" class="layui-btn layui-btn-primary">重置</button>
		</div>
	</div>
</form>

<script>
layui.use(['form'], function(){
	var form = layui.form,
		$ = layui.$;
	
	$("#btnAddPrice").click(function(){
		
		var html = '<div class="layui-form-item">'+
						'<div class="layui-inline">'+
							'<label class="layui-form-label">最小个数：</label>'+
							'<div class="layui-input-inline">'+
								'<input name="min_num[]" value="" lay-verify="required" autocomplete="off" placeholder="请输入商品最小个数" class="layui-input" type="text">'+
							'</div>'+
						'</div>'+
						'<div class="layui-inline">'+
							'<label class="layui-form-label">最大个数：</label>'+
							'<div class="layui-input-inline">'+
								'<input name="max_num[]" value="" lay-verify="" placeholder="请输入商品最大个数" autocomplete="off" class="layui-input" type="text">'+
							'</div>'+
						'</div>'+
						'<div class="layui-inline">'+
							'<label class="layui-form-label">价格/元：</label>'+
							'<div class="layui-input-inline">'+
								'<input name="price[]" value="" lay-verify="required" placeholder="请输入商品价格(单位：元)" autocomplete="off" class="layui-input" type="text">'+
							'</div>'+
						'</div>'+
					'</div>';
		$(".submitForm").before(html);
		
	});
	
	return false;
	
});

</script>